import { createRouter, createWebHistory } from 'vue-router'

const router = createRouter({
  history: createWebHistory(import.meta.env.BASE_URL),
  routes: [
    {
      path: '/',
      name: 'home',
      component: () => import('../layouts/index.vue'),
      redirect: '/upgradePackage',
      children: [
        {
          path: '/upgradePackage',
          name: 'upgradePackage',
          component: () => import('../views/upgradePackage.vue'),
        },
        {
          path: '/topologyProcess',
          name: 'topologyProcess',
          component: () => import('../views/topologyProcess.vue'),
        },
        {
          path: '/upgradeScript',
          name: 'upgradeScript',
          component: () => import('../views/upgradeScript.vue'),
        },
      ],
    },
  ],
})

export default router
